/*
 * GameManager.h
 *
 *  Created on: 27/07/2010
 *      Author: alex
 */

#ifndef GAMEMANAGER_H_
#define GAMEMANAGER_H_

#include <SDL/SDL_framerate.h>
#include "states/State.h"


// Forward declarations.
class SDL_Surface;
class State;


class GameManager {

public:

	GameManager(int frameRate = 30);

	virtual ~GameManager();

	void run();

protected:

	SDL_Surface* screen;

	FPSmanager* manex;

	State* state;

	unsigned timer;

	unsigned dt;

	void changeState(StateType next);

};


#endif /* GAMEMANAGER_H_ */
